home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Suzy B Software 2
/
Suzy B Software CD-ROM 2 (1994).iso
/
extras
/
picmanip
/
idealimg
/
idealimg.txt
< prev
next >
Wrap
Text File
|
1995-04-27
|
8KB
|
132 lines
The Ideal Image Size Setter
by Chet Walters
If you didn't know, GEM .IMG files have some interesting
information in their headers. Some of this information is necessary
to decipher the compression scheme. Other of it tells what size in
bits width and height the image is. Important to us here, however, is
the information that tells for what device the image was intended or
created. This would be the size of the pixels of the device on which
the image was created or to which it is destined to be printed.
So far (that I know of) there are only two ST programs that pay
any attention to this pixel size information (though more should).
One is Touch Up by Migraph. The other is PageStream. Touch Up will
allow you to modify this information before you save an IMG. However,
that means you must load the IMG, modify the info in a dialog which
takes many mouse clicks and key presses, then you must save the IMG to
retain that info (and Touch Up is no speed demon at saving or loading
IMG's). PageStream (which is quite fast at loading IMG's as objects)
uses this information to decide what size the IMG will be when it's
imported as an object. I'm sure if you've used PGS you've encountered
this thorny little problem: you've imported an IMG as an object then
dropped it on the page only to have it end up a HUGE thing which you
cannot modify since it extends beyond the page edges.
What happens is that PGS reads the header of the IMG and the
header tells PGS that the IMG is intended for a device with pixels
that are, say, at a resolution of 95 x 95 DPI (about the size of the
pixels on the Atari SM124 monitor). Hence, if the IMG is 950 bits
wide by 1140 bits tall, PGS figures it should be 10 INCHES wide by 12
INCHES tall! YIKES! This makes the import bigger than an 8 by 11
page. Certainly not at all workable. Especially since you plan to
print the thing on a laser printer which has pixels at 300 DPI so the
IMG, dot for dot, should only be about 3.2 inches wide by 3.8 inches
high. Well, here's a fix!
Ideal IMG Sizer will set the header information on the IMG you
choose from the fileselector to the right size for your printer. You
have a choice of a 9 pin printer (120/144 DPI), a 24 pin printer
(180/180 DPI) or a laser printer (300/300 DPI). IMG's modified with
the sizer will import into PageStream (or Touch Up) at the exact dot
for dot pixel for bit size to print ideally on the printer you choose.
It's then easy to use the EDIT COORDINATES dialog of PGS to set the
size to 200%, 150% or whatever size (inchwise) you think the thing
should be. This also helps to preserve the aspect ratio of your
imported images for best looks when they print. And they DO look very
nice when printed at their ideal size.
The IMG sizer comes in two flavors. The flavor you will likely
use first is the 10K PRG named MANY_IMG.PRG. This program will let
you set the size of ALL the images in any directory path you choose
from the fileselector. That's _ALL_ the images, _NO_ questions asked.
First select your printer then set the path with the fileselector and
let the program do the rest. If you make a mistake, hit the CANCEL
button. If you aren't sure you chose the right printer, hold the
SHIFT key when you hit any button on the main Alert and you can set
the printer again. The MANY_IMG.PRG program was written in GFA Basic
and there is little error checking. It will not damage any files, but
it may well crash if it encounters a READ ONLY file or a disk that's
bad or write protected. I recommend you use the MANY_IMG program only
at first when you have several diskfulls of IMGs which need sized (now
that you know you can do it easily). You should then tuck it safely
away and use the accessory/program described below.
The second flavor is the 2K IDEALIMG.ACC. This works directly in
PageStream or Touch Up or anywhere the DESK menu is available. It
will size only one IMG at a time until you hit the CANCEL button of
the fileselector. Use this to set the size of IMG's __BEFORE__ you
import them into PGS, TU or any other DTP program.
The first time the ACC is invoked, you will be asked to select a
printer. Click the button which corresponds to the printer to which
you ultimately plan to dump the IMG. You won't see this printer
selection box again as long as the machine is not RESET or turned off
unless you really want to. If for any reason you need to change the
printer (or just to ease your mind that you've chosen the right one)
PRESS and HOLD the SHIFT key as you click on the IDEAL IMAGES name
under the DESK MENU (or from MultiDesk). Continue to HOLD the SHIFT
key down until the printer selection box appears. Change the default
to the printer you wish.
Any time the IDEAL IMAGES accessory is invoked after you've
selected the printer, it will take you directly to the fileselector.
Choose the IMG file you wish to size (remember, do it _BEFORE_ you
import it into the program currently running). The ".IMG" extender
will be automatically appended to the filename so you can't
accidentally modify a file that's not an image (just in case you
really worked to fool the program into thinking that the PI3 Degas
file you double clicked was an IMG file). The image chosen will be
modified and the fileselector will re-appear with the name of the file
you just changed on the selection line (to remind you or, in case of
error, to show you which file was bad). Make another choice, or hit
the CANCEL button to exit the accessory. Short, sweet and simple!
Remember! With IDEAL IMAGES, no news is good news. If the you
don't get an error alert, then everything went fine. You will be
surprised at how quickly this accessory works (we did it this way to
reduce the window redraws that PGS or any other program currently
running must perform). And, there's a bonus! If you wish, you can
rename the IDEALIMG.ACC file to IDEALIMG.PRG and it will also run from
the desktop as a program! Hooray! No more HUMONGOUS out-of-aspect
images dropping all over the windows of PageStream! No more load,
edit cumbersome dialog, resave hassle with Touch Up to resize IMG's
for your printer!
I have released several programs recently into the ShareWare
market. They have seen print in Z-net, The ShareWare Connection,
PSAN, and have been included on the ST World disk of the month.
Unfortunately, I have received _NO_ donations for these efforts (not
even a 'Hi! How ya doin'?" note in my PO BOX). In fact, I had
intended to modify my COMPACT DIR program to include a sort feature
and also a 'mask' which will let you set types of files to include or
exclude from the printout. However, due to the poor response from the
folks who USE ShareWare products without a care in the world for the
folks who WRITE ShareWare products, this (an other) projects have been
permanently shelved. At this time, I write things only if I need them
MYSELF. I had a need for the IDEAL IMAGE SIZER so I wrote it. No
bells, no whistles, just an easy to use program that does the job
without taking up too much time or effort.
So, in light of this, I won't ask for donations for IDEAL IMAGE
SIZER. However, if you like it, if you find it helpful, if you find
it easy to use and worth including in your desk accessory collection,
send me a "Hi! How ya doin'?" note just so I know that there really is
somebody else out there who owns an ST. If you include five bucks in
the envelope, so much the better (tho I'll probably be so surprised
I'll have a coronary right there in the lobby of the post office!)
Chet Walters
PO Box 45
Girard, Ohio 44420